package com.songminju.jsong_httpserver;

public class HttpServerConfig implements Cloneable{
	
	private int port;
	private HttpHandler hander;
	private int maxConnection;
	private int maxThread;
	private int minSpareThreads;
	private int timeout;//单位为秒
	
	public HttpServerConfig() {
		this.port = 80;
	}
	
	public HttpServerConfig(int port,HttpHandler httpHander) {
		this.port = port;
		this.hander = httpHander;
	}

	public int getPort() {
		return port;
	}

	public void setPort(int port) {
		this.port = port;
	}

	public HttpHandler getHander() {
		return hander;
	}

	public void setHander(HttpHandler hander) {
		this.hander = hander;
	}

	public int getMaxConnection() {
		return maxConnection;
	}

	public void setMaxConnection(int maxConnection) {
		this.maxConnection = maxConnection;
	}

	public int getMaxThread() {
		return maxThread;
	}

	public void setMaxThread(int maxThread) {
		this.maxThread = maxThread;
	}

	public int getMinSpareThreads() {
		return minSpareThreads;
	}

	public void setMinSpareThreads(int minSpareThreads) {
		this.minSpareThreads = minSpareThreads;
	}

	public int getTimeout() {
		return timeout;
	}

	public void setTimeout(int timeout) {
		this.timeout = timeout;
	}
	
	@Override
	public Object clone() throws CloneNotSupportedException {
		return super.clone();
	}
}
